import httpInstance from '@/utils/http.js'
//加入购物车
export function insertCartAPI ({id,count}) {
  return httpInstance({
    url: '/api/shopping-cart/info/',
    method:'POST',
    data:{
      id,
      count
    }
  })
}
//获取购物车
export function getCartListAPI () {
  return httpInstance({
    url: '/api/shopping-cart/info/',
  })
}
//删除购物车
export function delCartAPI(ids){
  return httpInstance({
    url: '/api/shopping-cart/info/delete_list/',
    method:'DELETE',
    data:{
      ids
    }
  })
}

/* //合并购物车
export function mergeCartAPI (data) {
  return httpInstance({
    url: `/api/shopping-cart/info/1`,
    method:'POST',
    data
  })
} */

